var sPanel = $("#sortable");
$(function() {
		
	$(".savePrioriy").bind("click",function(){
		var sort = sPanel.sortable("toArray");
		var qs = "";
		$.each(sort,function(i,id){
			qs+="&beans["+i+"].name="+id+"&beans["+i+"].priority="+i;
		});
		var url = navObj.admin.securole.core+navObj.admin.securole.savepriority;
		doPost(url,qs,function(){
			var rdl = navObj.admin.securole.core+navObj.admin.securole.priority;
			doGet(rdl);
		});
	}).button();	
	$( "#sortable" ).sortable();
	$( "#sortable" ).disableSelection();
	
});